window.onload = function() {
  applyDefaultValue(document.getElementById('searchText'), 'Search for...');
}
function applyDefaultValue(elem, val) {
  elem.style.color = '#AEAEAE';
  elem.value = val;
  elem.onfocus = function() {
    if(this.value == val) {
	  elem.style.color = '#08445F';	
      this.value = ''; //On focus, make blank
    }
  }
  
  elem.onblur = function() {
    if(this.value == '') {
	  elem.style.color = '#AEAEAE';
      this.value = val; //If it's not in focus, use declared value
    }
  }
 }